package com.huage.courseplatform.application.model.param;


import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Update;

import javax.validation.constraints.NotEmpty;
import java.io.Serializable;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value="设置参数",description="设置参数")
public class ConfigPARAM implements Serializable {
    private static final long serialVersionUID = 1L;

    @NotEmpty(message = "id不能为空", groups = Update.class)
    @ApiModelProperty(value = "id(更新可以不传)",required = true)
    private String id;

    @NotEmpty(message = "配置名称不能为空",groups = {Update.class,Insert.class})
    @ApiModelProperty(value = "配置名称",required = true)
    private String name;

    @NotEmpty(message = "值不能为空",groups = {Update.class,Insert.class})
    @ApiModelProperty(value = "值",required = true)
    private String value;

    @NotEmpty(message = "编码不能为空",groups = {Update.class,Insert.class})
    @ApiModelProperty(value = "编码",required = true)
    private String code;

    @ApiModelProperty(value = "描述")
    private String description;


}
